`;
htmlDivMain+= `
`;
htmlDivMain+= `
`;
htmlDivMain+= `Failed to load, try again with reload.`;
htmlDivMain+= ``;
htmlDivMain+= `
`;
htmlDivMain+= ``;
htmlDivMain+= `
`;
htmlDivMain+= `
`;
htmlDivMain+= `
`;
htmlDivMain+= ``;
htmlDivMain+= ``;
htmlDivMain+= `
`;
htmlDivMain+= `
`;
htmlDivMain+= ``;
var divCode=d.createElement("div");
divCode.id='contentRoofCal';
divCode.style.display='flex';
divCode.innerHTML=htmlDivMain;
iframeLoad.body.append(divCode);
// creando script de gogle map place
if(!iframeLoad.querySelector("#apiMap")){
var s=d.createElement('script');
s.type="text/javascript";
s.id="apiMap";
s.async=!0;
s.src="https://maps.googleapis.com/maps/api/js?key=AIzaSyCEA1_kvJc0-Cpqo5_FvFP2wJxWjsPP0Ok&libraries=places,drawing,geometry&v=weekly";
//s.src="https://maps.googleapis.com/maps/api/js?key=AIzaSyD4EnKn-u2jXwq0KPQSadqX7YaS4OYDrgw&libraries=places";
iframeLoad.body.append(s)
}
setLS('estimate', estimate);
setLS('calculator', calculator);
var openRoofCal = function(){
console.log('click openRoofCal')
// iframeRoof.classList.toggle();
if(imgLogo!='' || desc_company!=''){
setTimeout(function(){ iframeLoad.querySelector('.sectLogo').style.display='flex'; }, 2000);
}
showLoading();
document.querySelector('#btnOpenRoofCal').classList.add('btnNone');
document.querySelector("#"+appRoofCal).classList.add('appActive');
if(window.innerWidth > 768){
Q('#contentRoofCal').style.display="flex";
}else{
Q('#contentRoofCal').style.display="block";
}
getLS('calculator');
if(calculator.step > 0){
stepCount = calculator.step
showLoading();
}else{
stepCount=0;
calculator.step = stepCount;
setLS('calculator', calculator);
console.log("redirect", redirect);
if(!Q("#zipcode")){
fetchStepHTML(estimate);
}else{
showLoading();
}
}
}
document.querySelector('#btnOpenRoofCal').addEventListener('click', (event) => {
event.preventDefault();
openRoofCal();
})